﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ESS_ChooseApprovalLine.aspx.cs" 
Inherits="KPIS.GERP.ESS.APP.App_UI.Forms.ESS_ChooseApprovalLine" MasterPageFile="/MasterLight.Master" %>

<asp:Content runat="server" contentplaceholderid="head">
    <title>สายบังคับบัญชา</title>
    <link href="../Styles/StyleSheet.css" rel="stylesheet" type="text/css" />
</asp:Content>

<asp:Content runat="server" contentplaceholderid="ContentPlaceHolder1">
     
    <div>
        <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
            <AjaxSettings>
                <telerik:AjaxSetting AjaxControlID="RadTreeList1">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="RadTreeList1" />
                    </UpdatedControls>
                </telerik:AjaxSetting> 
                <telerik:AjaxSetting AjaxControlID="RadTreeList2">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="RadTreeList2" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
                <telerik:AjaxSetting AjaxControlID="RadTreeView1">
                    <UpdatedControls>
                        <telerik:AjaxUpdatedControl ControlID="RadTreeView1" />
                    </UpdatedControls>
                </telerik:AjaxSetting>
            </AjaxSettings>
        </telerik:RadAjaxManager>
        
        <div class="DivBigTitle">
            เจ้าของรายการ<asp:Label ID="lblSender" runat="server" Font-Bold="true" />
        </div>

        <div class="BlockShadow" >
            <div class="DivSubTitle">
                ส่งไปตามเส้นทางการขออนุมัติ
            </div>
            <hr class="HrFadeLeftToRight"/>
            <table cellpadding="1" cellspacing="1" width="100%" height="100px">
                <tr>
                    <td valign="top">
                        <telerik:RadTreeList ID="rtlRadApprovalPath" runat="server" Width="100%" AutoGenerateColumns="False"
                            DataKeyNames="send_seq" ParentDataKeyNames="from_send_seq" 
                            GridLines="None" onitemcommand="rtlRadApprovalPath_ItemCommand">
                            <ExportSettings ExportMode="RemoveControls">
                            <Excel PageLeftMargin="0.7in" PageRightMargin="0.7in"></Excel>

                            <Pdf PageWidth="8.5in" PageHeight="11in"></Pdf>
                            </ExportSettings>

                            <EditFormSettings EditFormType="AutoGenerated">
                            <EditColumn MinWidth="" MaxWidth=""></EditColumn>
                            </EditFormSettings>
                            <Columns>
                                
                                <telerik:TreeListBoundColumn DataField="to_user_name" 
                                UniqueName="to_user_name" HeaderText="ชื่อผู้รับ">
                                    <HeaderStyle HorizontalAlign="Center" />
                                </telerik:TreeListBoundColumn>

                                <telerik:TreeListBoundColumn DataField="send_date" UniqueName="send_date" 
                                HeaderText="วันที่ส่ง/ตีกลับ/อนุมัติ" DataFormatString="{0:d}">
                                    <HeaderStyle Width="150px" HorizontalAlign="Center" />
                                    <ItemStyle HorizontalAlign="Center" />
                                </telerik:TreeListBoundColumn>

                                <telerik:TreeListBoundColumn DataField="reply_type_name" UniqueName="reply_type_name" 
                                HeaderText="สถานะ">
                                    <HeaderStyle Width="100px" HorizontalAlign="Center" />
                                    <ItemStyle HorizontalAlign="Center" />
                                </telerik:TreeListBoundColumn>  

                                <telerik:TreeListTemplateColumn MaxWidth="" MinWidth="" HeaderText="แจ้งเตือน"
                                    UniqueName="TemplateColumn"> 
                                    <HeaderStyle Width="64px" HorizontalAlign="Center" />
                                    <ItemStyle HorizontalAlign="Center" />
                                    <ItemTemplate>
                                        <asp:CheckBox runat="server"/>
                                    </ItemTemplate> 
                                </telerik:TreeListTemplateColumn>

                                <telerik:TreeListTemplateColumn UniqueName="TemplateColumn"> 
                                    <HeaderStyle Width="64px" HorizontalAlign="Center" />
                                    <ItemStyle HorizontalAlign="Center" />
                                    <ItemTemplate>
                                        <asp:LinkButton ID="LinkButton1" runat="server" Text="เลือก"/>
                                    </ItemTemplate> 
                                </telerik:TreeListTemplateColumn>

                            </Columns>
                        </telerik:RadTreeList>
                    </td>
                </tr>
            </table>    
        </div>
        
        <div class="BlockShadow" >
            <div class="DivSubTitle">
                ส่งไปตามเส้นสายบังคับบัญชา
            </div>
            <hr class="HrFadeLeftToRight"/>
            <table>
                <tr>
                    <td style="padding-left: 25px;">
                        <div class="RoundPersonalItem BackgroundPersonalItemBlue" style="width:20px; height: 5px;"/> 
                    </td>
                    <td>
                        พนักงาน
                    </td>
                    <td style="padding-left: 25px;">
                        <div class="RoundPersonalItem BackgroundPersonalItemPink" style="width:20px; height: 5px;" />
                    </td>
                    <td>
                        ผู้ที่อยู่ในสายบังคับบัญชา
                    </td>
                    <td style="padding-left: 25px;" >
                        <div class="RoundPersonalItem BackgroundPersonalItemYellow" style="width:20px; height: 5px;" />
                    </td>
                    <td >
                        ท่าน
                    </td>
                </tr>
            </table>
                                
            <table width="100%"> 
                <tr>
                    <td>
                        <div>
                            <telerik:RadTreeList ID="rtlRadApprovalLine" runat="server" Width="100%" AutoGenerateColumns="false"
                                AllowLoadOnDemand="false" AllowPaging="false" AllowSorting="false"
                                DataKeyNames="ID" ParentDataKeyNames="parent_ID" GridLines="None" 
                                onitemcommand="rtlRadApprovalLine_ItemCommand">
                                <Columns>
                                    
                                    <telerik:TreeListBoundColumn DataField="pos_name" UniqueName="pos_name" 
                                    HeaderText="ตำแหน่ง">
                                        <HeaderStyle HorizontalAlign="Center" /> 
                                    </telerik:TreeListBoundColumn>

                                    <telerik:TreeListTemplateColumn DataField="emp_name" UniqueName="emp_name" 
                                    HeaderText="ชื่อพนักงาน">
                                        <HeaderStyle HorizontalAlign="Center"  Width="220px"  />
                                        <ItemTemplate>
                                            <div >
                                                <%# Eval("emp_name") %>
                                            </div>
                                        </ItemTemplate>
                                    </telerik:TreeListTemplateColumn>

                                    <telerik:TreeListTemplateColumn MaxWidth="" MinWidth="" HeaderText="แจ้งเตือน"
                                        UniqueName="TemplateColumn"> 
                                        <HeaderStyle Width="64px" HorizontalAlign="Center" />
                                        <ItemStyle HorizontalAlign="Center" />
                                        <ItemTemplate>
                                            <asp:CheckBox ID="CheckBox1" runat="server"/>
                                        </ItemTemplate> 
                                    </telerik:TreeListTemplateColumn>

                                    <telerik:TreeListTemplateColumn MaxWidth="" MinWidth="" 
                                        UniqueName="TemplateColumn"> 
                                        <HeaderStyle Width="64px" HorizontalAlign="Center" />
                                        <ItemStyle HorizontalAlign="Center" />
                                        <ItemTemplate>
                                            <asp:LinkButton runat="server" Text="เลือก"/>
                                        </ItemTemplate> 
                                    </telerik:TreeListTemplateColumn>
                                    
                                    <telerik:TreeListBoundColumn DataField="exec_pos_name_parentheses" 
                                    UniqueName="exec_pos_name_parentheses"  Visible="False">
                                    </telerik:TreeListBoundColumn>

                                    <telerik:TreeListBoundColumn DataField="emp_type_name" 
                                    UniqueName="emp_type_name"  Visible="False">
                                    </telerik:TreeListBoundColumn>

                                    <telerik:TreeListBoundColumn DataField="job_site_name" 
                                    UniqueName="job_site_name"  Visible="False">
                                    </telerik:TreeListBoundColumn>

                                    <telerik:TreeListBoundColumn DataField="internal_job_site_name" 
                                    UniqueName="internal_job_site_name"  Visible="False">
                                    </telerik:TreeListBoundColumn>

                                    <telerik:TreeListBoundColumn DataField="emp_seq" UniqueName="emp_seq" 
                                    HeaderText="emp_seq" Visible="False">
                                    </telerik:TreeListBoundColumn>

                                    <telerik:TreeListBoundColumn DataField="ID" UniqueName="ID"  Visible="False">
                                    </telerik:TreeListBoundColumn>

                                    <telerik:TreeListBoundColumn DataField="parent_ID" UniqueName="parent_ID"  
                                    Visible="False">
                                    </telerik:TreeListBoundColumn>

                                </Columns>
                            </telerik:RadTreeList>
                        </div> 
                    </td>
                </tr>
            </table>
        </div>
    </div>
    <asp:HiddenField ID="hdfMode" runat="server" />
    <asp:HiddenField ID="hdfApprovePathSeq" runat="server" />
    <asp:HiddenField ID="hdfNewApprovePathSeq" runat="server" />
    <asp:HiddenField ID="hdfSendSeq" runat="server" />
</asp:Content>